package router

import (
	"github.com/gin-gonic/gin"
	"mxshop-api/api"
	"mxshop-api/middlewares"
)

func InitUserRouter(r *gin.RouterGroup) *gin.RouterGroup {
	router := r.Group("user")
	{
		router.GET("list", middlewares.JWTAuth(), middlewares.IsAdmin(), api.GetUserList)
		router.POST("login", api.PassWordLogin)
	}
	return router
}
